<template>
    <div class="MyBreadcrumb">
        <el-breadcrumb separator-class="el-icon-arrow-right">
            <el-breadcrumb-item :to="{ path: '/welcome' }">首页</el-breadcrumb-item>
            <el-breadcrumb-item v-for="(v,i) in item[0]" :key="i">{{v}}</el-breadcrumb-item>
        </el-breadcrumb>
    </div>
</template>
<script>
export default{
    name:'MyBreadcrumb',
    data() {
        return {
            item:[]
        } 

    },
    mounted(){
        let {matched}=this.$route;
        this.item.push(matched.map((item)=>{return item.meta.title}))
       //console.log(this.item);
        
    },
}
</script>
<style lang="scss">
    .MyBreadcrumb{
        
    }
</style>